<template>
  <div class="goods">
    <goods-list-item v-for="item in goods" :key="item.id" :product="item"></goods-list-item>
  </div>
</template>

<script>
import GoodsListItem from "@/components/goods/GoodsListItem";

export default {
  name: "GoodsList",
  props: {
    goods: {
      type: Array,
      default() {
        return []
      }
    }
  },
  components: {
    GoodsListItem
  }
}
</script>

<style scoped lang="scss">
.goods {
  display: flex;
  /*自动换行*/
  flex-wrap: wrap;
  /*四周环绕*/
  justify-content: space-around;
  padding: 5px;
}
</style>
